" helper functions for move all files in child directories to root from ls -l {{{1
function! MoveAllToRootFunction()
  " wrapping is evil
  set nowrap
  " remove everything but dir lines
  v/^d/d
  " remove excessive ls information
  g/./normal 8daW
  " wrap in double quote
  g/./normal i"
  g/./normal g$a"
  " duplicate line and make command
  g/./normal yypkg$a/* .; rmdirjlJ
  " fix head
  g/./normal Imv jl
  " output
  write! /tmp/vim-gen-moveAllToRoot.fish
  " quit
  q!
endfunction
